package com.hktf.corelib.constant;

public enum ActiveType {
    TYPE8(8),//更换车辆
    TYPE1(1),//驾驶优化
    TYPE2(2),//自主诊断
    TYPE3(3),//出车自检
    TYPE4(4),//年检
    TYPE5(5),//附近页自主诊断
    TYPE6(6),//附近页远程协助
    TYPE7(7),//设备信息
    TYPE9(9),//头像
    ;

    private int type;

    ActiveType(int type) {
        this.type = type;
    }

    public int getType() {
        return type;
    }

    public void setType(int type) {
        this.type = type;
    }

    public static ActiveType getbyType(int type){
        ActiveType activeType=null;
        switch (type) {
            case 1:
                activeType= TYPE1;
                break;
            case 2:
                activeType= TYPE2;
                break;
            case 3:
                activeType= TYPE3;
                break;
            case 4:
                activeType= TYPE4;
                break;
            case 5:
                activeType= TYPE5;
                break;
            case 6:
                activeType= TYPE6;
                break;
            case 7:
                activeType= TYPE7;
                break;
            case 8:
                activeType= TYPE8;
                break;
        }
        return activeType;
    }
}
